﻿<u:UObject x:Class="UTable.Tests.UPopupTest"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:u="clr-namespace:UTable.Objects.Controls;assembly=UTable.Core"
    xmlns:up="clr-namespace:UTable.Objects.Controls.Primitives;assembly=UTable.Core"
    Height="400" Width="400">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="246*" />
            <RowDefinition Height="165" />
        </Grid.RowDefinitions>
        <u:UToggleButton Margin="139,91,138,92" x:Name="ShowButton" 
                         Checked="ShowButton_Checked" Unchecked="ShowButton_Unchecked">Show Popup</u:UToggleButton>
        <up:UPopup x:Name="MyPopup" Grid.RowSpan="2" Height="60" Width="120">
            <Grid Background="White">
                <TextBlock Text="I am a popup" FontSize="16" HorizontalAlignment="Right" VerticalAlignment="Center" Height="21.28" Margin="0,0,12.943,0" Width="94.113" />
            </Grid>
        </up:UPopup>
        <Grid Grid.Row="1">
            <TextBlock Text="Placement:" FontSize="18" Foreground="White" Height="28" HorizontalAlignment="Left" VerticalAlignment="Top" Width="103" Margin="6,6,0,0" />
            <u:UComboBox Height="39" VerticalAlignment="Top" Width="146" SelectedIndex="0" FontSize="16" Foreground="White" x:Name="DirectionBox" SelectionChanged="DirectionBox_SelectionChanged" Margin="100.057,0,151.943,0">
                <u:UComboBoxItem>Top</u:UComboBoxItem>
                <u:UComboBoxItem>Left</u:UComboBoxItem>
                <u:UComboBoxItem>Bottom</u:UComboBoxItem>
                <u:UComboBoxItem>Right</u:UComboBoxItem>
                <u:UComboBoxItem>Relative</u:UComboBoxItem>
                <u:UComboBoxItem>Absolute</u:UComboBoxItem>
            </u:UComboBox>
            <TextBlock Text="OffsetX:" FontSize="18" Foreground="White" Margin="6,55,-6,69" />
            <TextBlock Text="OffsetY:" FontSize="18" Foreground="White" Margin="6,0,-6,17" Height="28" VerticalAlignment="Bottom" />
            <u:USlider x:Name="OffsetXSlider" Minimum="10" Maximum="200" SnapsToDevicePixels="True" Value="10" ValueChanged="OffsetXSlider_ValueChanged" Height="32" Margin="100.057,51,6,69" Width="291.943" />
            <u:USlider x:Name="OffsetYSlider" Minimum="10" Maximum="200" SnapsToDevicePixels="True" Value="10" ValueChanged="OffsetYSlider_ValueChanged"  Height="32" Margin="100.057,0,6,17" Width="291.943" VerticalAlignment="Bottom" />
        </Grid>
    </Grid>
</u:UObject>
